/**
 * elancom Corporation copy right 2012 - 2015  
 *   
 * $Header: https://192.168.1.224/svn/elancom/product/elancom-platform/trunk/src/main/java/com/elancom/framework/commons/json/parser/JSONLexer.java 1034 2012-07-02 03:09:12Z lanzhouxue $
 * $Id: JSONLexer.java 1034 2012-07-02 03:09:12Z lanzhouxue $
 * $Author: lanzhouxue $
 * $Date: 2012-07-02 11:09:12 +0800 (Mon, 02 Jul 2012) $
 * $Revision: 1034 $
 */
package com.elancom.framework.commons.json.parser;

import java.math.BigDecimal;
import java.util.Calendar;

/**
 * @author elancom
 */
public interface JSONLexer {
	boolean isResetFlag();

	void setResetFlag(boolean resetFlag);

	void nextToken();

	void nextToken(int expect);

	int token();

	String tokenName();

	int pos();

	String stringVal();

	Number integerValue();

	void nextTokenWithColon(int expect);

	BigDecimal decimalValue();

	Number decimalValue(boolean decimal);

	double doubleValue();

	float floatValue();

	void config(Feature feature, boolean state);

	boolean isEnabled(Feature feature);

	String numberString();

	boolean isEOF();

	String symbol(SymbolTable symbolTable);

	boolean isBlankInput();

	char getCurrent();

	void skipWhitespace();

	void incrementBufferPosition();

	String scanSymbol(final SymbolTable symbolTable);

	String scanSymbol(final SymbolTable symbolTable, final char quote);

	void resetStringPosition();

	String scanSymbolUnQuoted(final SymbolTable symbolTable);

	void scanString();

	void scanNumber();

	boolean scanISO8601DateIfMatch();

	Calendar getCalendar();

	int intValue() throws NumberFormatException;

	long longValue() throws NumberFormatException;

	byte[] bytesValue();

	void close();
}
